import CryptoJS from 'crypto-js'
export const encryData = (data:any) => {
    let key = 'luox'
    data = encodeURIComponent(CryptoJS.AES.encrypt(JSON.stringify(data), key).toString())
    return data
  }
    // 解密
  export const decryData = (data:any) => {
    data = decodeURIComponent(data)
    let key = 'luox'
    data = CryptoJS.AES.decrypt(data, key).toString(CryptoJS.enc.Utf8)
    return JSON.parse(data)
  }